package org.testis.gui.mvc.utilities;

import javax.swing.JProgressBar;


/**
 *
 * @author nurhat
 */
public class AtofProgressBar extends JProgressBar
{
    private static final long serialVersionUID = 70322L;

    /** True if the progress bar is indeterminate,  xxxxx wise false */
    private boolean m_indeterminate = false;


    /**
     * Creates a progress bar
     */
    public AtofProgressBar()
    {
        super();
    }


    /**
     * Override setIndeterminate to cause NPE
     */
    @Override
    public void setIndeterminate(boolean newValue)
    {
        m_indeterminate = newValue;
        super.setIndeterminate(newValue);
    }


    /**
     * Override isIndeterminate. If we don't, we don't get the NPE.
     */
    @Override
    public boolean isIndeterminate()
    {
        return m_indeterminate;
    }
}
